﻿using System;
using System.Collections.Generic;
using System.Linq;
#if !NETCOREAPP
using System.Web;
using System.Web.Mvc;
using System.Web.WebPages;
    using System.Web.Mvc.Html;

#endif

#if NETCOREAPP
using Microsoft.AspNetCore.Mvc.Rendering;
using Kugar.Core.Web;
#endif

namespace Kugar.MVC.MobileUI.WeUI.PageControls.PageForm
{
    public class PageForm_Label:PageForm_FieldBase
    {
        private string _value = "";

        public PageForm_Label(ViewContext viewContext) : base(viewContext)
        {
        }

        public PageForm_Label Value(string text)
        {
            _value = text;

            return this;
        }

        protected override void RenderBody()
        {
            ViewContext.Writer.WriteLine("<p>");

            ViewContext.Writer.WriteLine(_value);

            ViewContext.Writer.WriteLine("</p>");
        }
    }
}